package org.ece3574.WTParty;

import java.util.ArrayList;

import android.app.AlertDialog;
import android.content.Context;
import android.graphics.drawable.Drawable;

import com.google.android.maps.ItemizedOverlay;
import com.google.android.maps.OverlayItem;

public class MapOverlay extends ItemizedOverlay<OverlayItem> {

	protected ArrayList<OverlayItem> mOverlays = new ArrayList<OverlayItem>();
	private Context mContext;

	public MapOverlay(Drawable defaultMarker, Context context) {
		super(boundCenterBottom(defaultMarker));
		mContext = context;
		populate();
	}
// Add overlay
	public void addOverlay(OverlayItem overlay) {
		mOverlays.add(overlay);
		populate();
	}
// Overlay item
	@Override
	protected OverlayItem createItem(int i) {
		return mOverlays.get(i);
	}
// Overlay size
	@Override
	public int size() {
		return mOverlays.size();
	}

}
